from django.db import models

# Create your models here.
#------------------最新数据库---------------
# class DataUpload(models.Model):
#     data_type = models.IntegerField(default=0)
#     data_group = models.IntegerField(default=0)
#     data_content = models.TextField()
#     data_upload_time = models.DateTimeField(auto_now_add=True)
#     publisher_id = models.IntegerField(default=0)
#     class Meta:
#         db_table = 'DataUpload'
#
#
#
# class Task(models.Model):
#     task_name = models.CharField(max_length=50, default=0)
#     task_status = models.IntegerField(default=0)
#     task_publish_id = models.IntegerField(default=0)
#     task_type = models.IntegerField(default=0)
#     task_publish_time = models.DateTimeField(auto_now_add=True)
#     task_salary = models.IntegerField(default=0)
#     task_description = models.CharField(max_length=200, default=0)
#     task_rank = models.IntegerField(default=0)
#     task_settings = models.CharField(max_length=200, default=0)
#     class Meta:
#         db_table = 'Task'
#
#
# class Taskdata(models.Model):
#     taskdata_id = models.OneToOneField(DataUpload, primary_key=True, on_delete=models.CASCADE)
#     taskdata_task_id = models.IntegerField(default=0)
#     taskdata_assign = models.IntegerField(default=0)
#     taskdata_result = models.CharField(max_length=2000)  # 是多样化的数据
#     taskdata_content = models.TextField()
#     class Meta:
#         db_table = 'Taskdata'
from task_market.models import DataUpload,Task,Taskdata
from user_mng.models import users
# class DataUpload(models.Model):
#     data_type = models.IntegerField(default=0)
#     data_group = models.IntegerField(default=0)
#     data_content = models.TextField()
#     data_upload_time = models.DateTimeField(auto_now_add=True)
#     publisher_id = models.CharField(max_length=50, default='0')
#     class Meta:
#         db_table = 'DataUpload'
#
#
# class Task(models.Model):
#     task_name = models.CharField(max_length=50, default=0)
#     task_status = models.IntegerField(default=0)
#     task_publish_id = models.CharField(max_length=50, default='0')  # 发布者id
#     task_type = models.CharField(max_length=50, default=0)
#     task_publish_time = models.DateTimeField(auto_now_add=True)
#     task_salary = models.FloatField(default=0)
#     task_description = models.CharField(max_length=200, default=0)
#     task_rank = models.CharField(max_length=200, default='一级')
#     task_settings = models.CharField(max_length=2000, default=0)  # 项目设置
#     class Meta:
#         db_table = 'Task'
#
#
# class Taskdata(models.Model):
#     taskdata_id = models.CharField(max_length=50, default='0') # 和DataUpLoad自动生成id对应
#     taskdata_task_id = models.CharField(max_length=50, default='0')  # 所属任务id
#     taskdata_assign = models.CharField(max_length=50, default=0)  # 标注员id
#     taskdata_result = models.CharField(max_length=2000)  # 标注结果
#     taskdata_content = models.TextField()
#     class Meta:
#         db_table = 'Taskdata'